home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Languages / MPW Oberon 2.1168 / OExamples / MakeFile < prev    next >
Encoding:
Makefile  |  1994-12-12  |  3.6 KB  |  105 lines  |  [TEXT/MPS ]

  1. #    MakeFile    -  Make instructions for Oberon examples.
  2. #
  3. #    Copyright Apple Computer, Inc. 1986-1993
  4. #    All rights reserved.
  5. #
  6. #    This makefile builds:
  7. #        The sample Pascal tool:         ResEqual
  8. #        The sample desk accessory:        DAMemory
  9. #        The sample Performance Tool:     TestPerf
  10. #
  11.  
  12. #     You can define {SymOptions} as "-sym on" or "-sym off" for use with SADE
  13.  
  14. OOptions = -s {SymOptions}
  15.  
  16. .mod.o ƒ .mod
  17.     Oberon {OOptions} {DepDir}{Default}.mod -o {TargDir}{Default}.mod.o
  18.  
  19. #    The following two variables define the creator and type for the
  20. #    Memory Desk Accessory.  For System 6 compatibility, the build
  21. #    instructions should create a "Suitcase" file containing the DA.
  22. #    Suitcase files have a creator of 'DMOV' and a type of 'DFIL'.  For
  23. #    System 7 and newer, DA's can exist all by themselves, without being
  24. #    wrapped in the "womb" of the Suitcase file.  This makes it easier
  25. #    to manipulate the DA file, since the Suitcase doesn't have to be
  26. #    opened first.  DA's can be treated just like any other application.
  27. #    In this case, the creator should be 'movr' and the type should be
  28. #    'dfil' (note the difference in character case).
  29.  
  30. DACreator    =    'movr'    # change to 'DMOV' for System 6 use
  31. DAType        =    'dfil'    # change to 'DFIL' for System 6 use
  32.  
  33. # The following variable is used to define the ROM map file used by the
  34. # TestPerf component.  If necessary, you can change this to point to the
  35. # proper location of your machine's ROM map.
  36.  
  37. RomMap          =    "{MPW}ROM Maps:Mac`gestalt mach -s`ROM.map"
  38.  
  39. #######################################################################
  40. # Build instructions and dependencies for the ResEqual tool
  41. #
  42.  
  43. ResEqual        ƒƒ    ResEqual.r
  44.     Rez ResEqual.r -o ResEqual -append
  45. ResEqual        ƒƒ    ResEqual.mod.o FStubs.a.o
  46.     Link -w -c 'MPS ' -t MPST {SymOptions} ResEqual.mod.o FStubs.a.o ∂
  47.         -sn STDIO=Main ∂
  48.         -sn INTENV=Main ∂
  49.         -sn %A5Init=Init ∂
  50.         "{Libraries}"Interface.o ∂
  51.         "{Libraries}"Runtime.o ∂
  52.         "{Libraries}"ToolLibs.o ∂
  53.         "{PLibraries}"Paslib.o ∂
  54.         "{OLibraries}"OberonLib.o ∂
  55.         -o ResEqual
  56.  
  57.  
  58. #######################################################################
  59. # Build instructions and dependencies for the Memory desk accessory
  60. #
  61.  
  62. DAMemory            ƒƒ    DAMemory.mod.o DAEntry.a.o 
  63.     Link {SymOptions} -w -da -rt DRVR=12 ∂
  64.         -m DAEntry -sg DAMemory                # DAEntry is located in DAEntry.a.o ∂
  65.         DAEntry.a.o                            # This must preceed DRVRRuntime.o ∂
  66.         "{Libraries}"DRVRRuntime.o            # This must preceed DAMemory.p.o ∂
  67.         -ma DAMemory_DRVRControl=DRVRCONTROL -ma DAMemory_DRVROpen=DRVROPEN ∂
  68.         -ma DAMemory_DRVRClose=DRVRCLOSE -ma DAMemory_DRVRStatus=DRVRSTATUS ∂
  69.         -ma DAMemory_DRVRPrime=DRVRPRIME ∂
  70.         DAMemory.mod.o ∂
  71.         "{Libraries}"Interface.o ∂
  72.         "{PLibraries}"Paslib.o ∂
  73.         -o DAMemory -c {DACreator} -t {DAType}
  74.         
  75. DAMemory            ƒƒ    DAMemory.r
  76.     Rez -rd -c {DACreator} -t {DAType} DAMemory.r -a -o DAMemory
  77.  
  78. DAMemory.NOASM            ƒ    DAMemory.DRVW DAMemory.r
  79.     Rez -rd -c {DACreator} -t {DAType} -d NOASM_BUILD DAMemory.r -o DAMemory.NOASM
  80.     Duplicate -y DAMemory.NOASM DAMemory
  81.  
  82. DAMemory.DRVW     ƒ    DAMemory.mod.o
  83.     Link -w -rt DRVW=0 ∂
  84.         -sg DAMemory ∂
  85.         "{Libraries}"DRVRRuntime.o    # This must preceed DAMemory.mod.o ∂
  86.         DAMemory.mod.o ∂
  87.         "{Libraries}"Interface.o ∂
  88.         "{PLibraries}"Paslib.o ∂
  89.         -o DAMemory.DRVW -c "????" -t "????"
  90.  
  91.  
  92. #######################################################################
  93. # Build instructions and dependencies for the TestPerf tool
  94. #
  95.  
  96. TestPerf    ƒ    TestPerf.mod.o
  97.     Link -o TestPerf -t MPST -c 'MPS ' -d {SymOptions} ∂
  98.         -l -la > TestPerf.map # produce link map file ∂
  99.         TestPerf.mod.o "{Libraries}"PerformLib.o ∂
  100.         "{Libraries}"Interface.o ∂
  101.         "{Libraries}"Runtime.o ∂
  102.         "{PLibraries}"PasLib.o ∂
  103.         "{OLibraries}"OberonLib.o
  104.     Catenate {ROMMap} >>TestPerf.map
  105.